<h2>Create a New User</h2>
<? if ($message) : ?>
	<h3 class="message">
		<?= $message; ?>
	</h3>
<? endif; ?>

<?= Form::open('admin/user/create',array('class'=>'form-horizontal')); ?>
<div class="control-group">
	<?= Form::label('username', 'Tên đăng nhập',array('class'=>'control-label')); ?>
	<div class="controls">
		<?= Form::input('username', HTML::chars(Arr::get($_POST, 'username'))); ?>
		<div class="error">
			<?= Arr::get($errors, 'username'); ?>
		</div>
	</div>
</div>
<div class="control-group">
	<?= Form::label('email', 'Email',array('class'=>'control-label')); ?>
	<div class="controls">
		<?= Form::input('email', HTML::chars(Arr::get($_POST, 'email'))); ?>
	<div class="error">
		<?= Arr::get($errors, 'email'); ?>
	</div>
	</div>
</div>
<div class="control-group">
	<?= Form::label('password', 'Mật khẩu', array('class'=>'control-label')); ?>
	<div class="controls">
	<?= Form::password('password'); ?>
	<div class="error">
		<?= Arr::path($errors, '_external.password'); ?>
	</div>
</div>
</div>
<div class="control-group">
	<?= Form::label('password_confirm', 'Nhập lại mật khẩu',array('class'=>'control-label')); ?>
	<div class="controls">
		<?= Form::password('password_confirm'); ?>
		<div class="error">
			<?= Arr::path($errors, '_external.password_confirm'); ?>
		</div>
		</div>
</div>
<div class="control-group">
	<div class="controls">
	<?= Form::submit('create', 'Thêm mới',array('class'=>'btn btn-primary')); ?>
	<?= Form::submit('create', 'Hủy bỏ',array('class'=>'btn')); ?>
	</div>
</div>
	<?= Form::close(); ?>
 
